while True:
        a =input("请输入pm2.5的值,或者按Q退出程序")

        if a == "q":
            break
        elif int(a)>0 and int(a)<50:
            print("空气质量为优")
        elif int(a)>50 and int(a)<100:
            print("空气质量为良")
        elif int(a)>101 and int(a)<150:
            print("空气质量为轻度污染")
        elif int(a) > 151 and int(a) < 200:
            print("空气质量为中度污染")
        elif int(a) > 201 and int(a) < 300:
            print("空气质量为重度度污染")
        else:
            print("空气质量为严重污染")
